package com.example.demo.controller;

import com.example.demo.model.Result;
import com.example.demo.service.AboutOrderService;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/AboutOrderController")
@AllArgsConstructor
public class AboutOrderController {

    private AboutOrderService aboutOrderService;

    @GetMapping
    public Result getAllOrderHead(@RequestParam(defaultValue = "1") Integer current,
                                  @RequestParam(defaultValue = "10") Integer pageSize){
        return aboutOrderService.getAllOrderHead(current,pageSize);

    }

}
